﻿<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
    <title></title>
</head>
<body>
    <h1>这里是内嵌的框架</h1>

    <script type="text/javascript">
        window.onload = function () {
            window.addEventListener("message", function (event) {
                var outerContentWindow = event.source;
                alert(event.data);
                outerContentWindow.postMessage("hello i am innerFrame","*");
            }, false)
        }
    </script>
</body>
</html>
